Traditionally, in the method of controlling drive mechanisms such as a motor, so called “feedback control” in which the speed, position and the like of the motor itself or a controlled object connected to the motor is detected, and the motor is controlled according to the result of detection is well known. Examples of the apparatus using as a drive source the motor driven by such control include a recording apparatus.
An apparatus well known as this recording apparatus is a printer. In the printer, for example, so called a serial type printer having a recording head mounted thereon, and having a carriage undergoing scanning in a reciprocating manner in the direction vertical to the direction in which a recording medium (hereinafter referred to as “recording paper” or “paper”) such as a paper or film is transported, and carrying out recording by having the carriage scanned while transporting the recording paper is transported is widely adopted in terms of easy construction.
On the other hand, a various kinds of recording systems are used for the recording heads of these recording apparatuses. For the recording system, the wire dot system, heat-sensitive system, heat transfer system, ink jet system, electrophotographic system and the like are widely known, and above all, the ink jet system is widely used in terms of coloration, enhanced resolution and silence.
In this serial type printer, the scan drive of the carriage is one of the important technical factors in recording operations. For the drive source of the carriage, stepping motors and DC motors are used, and above all, the DC motor is used in conjunction with an encoder system detecting the speed and position of the carriage because the DC motor is excellent in silence compared to the stepping motor. The DC motor is generally driven by the feedback control system in which the speed and position of the carriage is detected by the encoder system, and the motor is controlled according to the deviations from the command speed and command position.
Furthermore, even if the stepping motor is used as a drive source, the encoder system may be used. Here, the command speed is a speed that should be essentially achieved in timing with which the speed of the carriage has been detected, and the command position is a position that should be reached in timing with which the position of the carriage has been detected.
Also, the method of controlling the scan drive of the carriage varies depends on the scan position of the carriage and the situation of recording operations. For example, unless the carriage is always scanned at almost a constant speed at the time of recording, it may be difficult to carry out recording in an appropriate position in a recording medium, thus raising the possibility that the quality of recorded products is compromised.
After passing through the recording area, on the other hand, the carriage must have its traveling speed reduced for stopping at a predetermined position. If the degree of this speed reduction is not appropriate, the carriage may fail to stop at the predetermined position, thus raising the possibility that the subsequent operations are hindered. From this point of view, in most instances, control is performed focusing on the speed so that the carriage can be scanned at an appropriate speed when the carriage undergoes acceleration and the carriage travels at a constant speed, and control is performed focusing on the position so that the carriage can be stopped at an appropriate position when the carriage has its speed reduced.
When the DC motor and encoder system described above are used to control the drive of the carriage, the following feedback control is often performed.
First, here, assuming that the feedback control process is carried out at predetermined time intervals, for example at intervals of 1 ms, the feedback control process will briefly be described below.
Based on the previously required ultimate target position and speed to be attained by the carriage, the ultimate speed and position to be attained by the carriage, i.e. command speed and command position are calculated at each time of control. Explaining one example of the process for calculating the command speed and command position at the time when the carriage undergoes acceleration here, the command speed V (t) and the command position X (t) of the carriage at each time of control are calculated from a preset acceleration distance L, an ultimate speed VT to be attained at the time when the carriage travels at a constant speed, and a preset acceleration α.
Assuming that acceleration α is a change in speed between control timing periods, for example, the value at each time of control is calculated for the command speed V (t) in accordance with the equation: V (t)=V (t−1)+α. Similarly, for the command position X (t), a command speed V (t) determined from the calculated command speed V (t) is added at each time of control, namely the command position X (t) is calculated in accordance with the equation: X (t)=V (t)+V (t−1)+ . . . .
Therefore, in this case, the command speed V (t) is a value linearly increasing with time to the speed reached at the time of traveling at a constant speed, and the command position X (t) is calculated as a value exponentially increasing to a value equivalent to the acceleration distance.
Furthermore, for the command speed V (t), the ultimate speed VT to be attained in the constant speed-region may be considered as the command speed at the time of acceleration without conducting the above calculation. In this case, the command speed V (t) is a fixed value that does not increase with time. Here, the subscript (t) refers to a value at predetermined time of control processing, and the subscript (t−1) refers to a value at the immediately previous time of processing.
Then, the actual position of the carriage is determined from the result of encoder system detection, and a deviation from the command position is calculated, and based on the result thereof, a speed controlled variable Vc (t) is calculated. Subsequently, a speed deviation VE (t) is calculated from the command speed V (t) and the actual speed v (t) of the carriage, and a new speed controlled variable Vc (t) is calculated based on this speed deviation VE (t).
Then, a controlled variable M to be applied to the motor according to this speed controlled variable Vc (t) is calculated, and this motor controlled variable M is applied to the motor to control the drive of the motor. As a result, the motor is driven in accordance with the command speed and command position.
In this way, the motor itself and the controlled object connected to the motor are driven in accordance with the command speed and command position to attain an ultimate speed (ultimate speed VT) and move to and stop at an ultimate position (ultimate target position XT), whereby a series of control is ended.
Also, whether the ultimate target position XT has been reached or not is determined as a general practice, and if it is determined that the position has been reached, application of the controlled variable (also called driven variable) to the motor is stopped and so on to proceed to the next operation as a general practice.
Here, if considering the operation of stopping at the ultimate target position XT, it is often difficult in general to have the object stopped at the ultimate target position XT, and therefore a predetermined range n, namely XT−n/2˜XT+n/2 is set for the ultimate target position XT, and when the controlled object stops in this range, it is determined that the controlled object moves to and stops at the ultimate target position and so on as a general practice.
However, the above method of controlling the motor and the recording apparatus using this method have the following problems.
That is, if the motor and the controlled object such as a carriage connected to the motor are driven so that the controlled object attains the ultimate speed and position in accordance with the command speed and command position, more than predetermined time may be required until the motor and the controlled object connected to the motor stop, or it is determined that they stop in the stopped state at the ultimate target position XT.
Also, time required for the motor and the controlled object to stop may vary considerably depending on apparatuses such that the motor and the controlled object can stop quickly for some apparatuses, and it takes much time for them to stop for other apparatuses.
In addition, a strange noise may be emitted in the stopped state at the ultimate target position XT.
In this situation, the motor has its speed reduced from its running condition to “0” before reaching the ultimate position, or does not have its speed reduced to “0” even after passing by the ultimate position, and so on, thus making it impossible to stop at the ultimate position.
This will be described using operations of the carriage of the recording apparatus as an example.
FIG. 20 is a graph showing the command speed V (t) and actual speed v (t) of the carriage and the motor controlled variant M versus time.
For example, reference character A in the figure shows a situation in which reduction in speed is started from the constant-speed state and the ultimate position is reached, but the position is passed by because the speed cannot be reduced enough, so that a slight movement is made in an opposite direction to consume time wastefully for stopping at the ultimate position. Here, time is similarly consumed wastefully in the case where the speed is reduced to “0” before the ultimate position is reached. That is, in this case, the stopped state occurs before the ultimate position is reached, and thereafter control is performed so that a movement to the ultimate position is made to make a slight movement.
In addition, if the parameter in feedback control or the like is inappropriate, oscillation may occur in the stopped state. Such a situation is shown in FIG. 21.
In this case, an acceptable range is set such that a predetermined range n including positions ahead and behind the ultimate target position XT, i.e. XT−n/2˜XT+n/2 is established, and it is determined that the carriage stops at the ultimate target position when the carriage stops at a point within the predetermined range n.
First, the upper part of FIG. 21 shows a situation in which the carriage moves from the left side in the figure toward the ultimate target position XT, and thereafter passes by the ultimate target position XT and further goes beyond the acceptable range even though the carriage is controlled. The carriage is controlled so as to go back to the ultimate target position XT from a certain position beyond the acceptable range, and therefore the carriage is driven in the opposite direction.
When the carriage is driven in the opposite direction, however, the carriage moves to a position at a longer distance from the ultimate target position XT than the previous position, and this movement is repeated to bring the carriage into an oscillation state, as shown. Here, FIG. 22 shows a relation between the position of the carriage and time when the carriage is brought into the oscillation state, and as shown in FIG. 22, it can be understood that the carriage moves to and from around the ultimate target position, and the movement of the carriage is not converged.
Also, the lower part of FIG. 21 shows a situation in which the carriage temporarily stops before the carriage reaches the acceptable range of the ultimate target position XT. Also in this case, the carriage is driven so that the carriage approaches to the ultimate target position XT after it temporarily stops, but the carriage passes by the ultimate target position XT and the acceptable range, and is consequently brought into the oscillation state as shown in FIG. 22.
Such phenomena are mainly ascribable to difficulty of optimization of controlled parameters. The principal reason for difficulty of optimization is that time delay occurs in so called a transfer system such as transfer between the motor and the carriage, and a period of time between the instant when the speed and position are detected by the encoder sensor and the instant when the motor gains a drive force by way of processing for feedback control, and the delayed time is different for each apparatus due to variations in parts of apparatuses, ambient temperature and humidity, and variations in performance of motors, and the load on the motor is different for each apparatus, and so on.
Also, for optimizing the controlled parameter and the like for the apparatus, it can be considered that so called “learning” in which the controlled parameter is changed predetermined timing to identify an optimal value is performed, but in this case, the apparatus should be driven for the “learning,” and therefore the apparatus cannot be operated efficiently. Also, in this case, the control method is complicated, and cannot be easily applied to inexpensive apparatuses.